// BaseLabelLoader.js
class BaseLabelLoader {
    constructor(app) {
        // console.log('BaseLabelLoader app = ', app);
        if (new.target === BaseLabelLoader) {
            throw new TypeError('Cannot construct BaseLabelLoader instances directly');
        }
        this.app = app;
        this.userDataPath = app ? app.userDataPath : null;
    }

    // 加载数据
    async load(label_info) {
        throw new Error("Handler method 'load' must be implemented by subclass.");
    }

    // 保存数据
    async save(label_info) {
        throw new Error("Handler method 'save' must be implemented by subclass.");
    }

    // 转换数据
    async fromStudio(label_info) {
        throw new Error("Handler method 'fromStudio' must be implemented by subclass.");
    }
}

module.exports = BaseLabelLoader;
